import request from '@/store/request'

export function retrieveSendMsg (mobile, sessionId) {
  return request({
    url: 'retrieve/sendMsg',
    method: 'POST',
    dataType: 'json',
    data: {
      mobile: mobile,
      sessionId: sessionId
    }
  })
}
export function retrieveCode (mobile, code) {
  return request({
    url: 'retrieve/code/' + mobile + '/' + code,
    method: 'get',
    dataType: 'json'
  })
}

export function updatePasswordByMobile (mobile, password, confirmPassword) {
  return request({
    url: 'retrieve/reset',
    method: 'post',
    dataType: 'json',
    data: {
      mobile: mobile,
      password: password,
      confirmPassword: confirmPassword
    }
  })
}
